<ui:composition xmlns="http://www.w3.org/1999/xhtml"
                xmlns:ui="http://java.sun.com/jsf/facelets"
                xmlns:h="http://java.sun.com/jsf/html"
                xmlns:f="http://java.sun.com/jsf/core"
                xmlns:p="http://primefaces.org/ui"
                template="/WEB-INF/template.xhtml">

    <ui:define name="title">
        SelectOneButton
    </ui:define>

    <ui:define name="description">
        SelectOneButton is used to choose a single item from a list using buttons.
    </ui:define>

    <ui:param name="documentationLink" value="/components/selectonebutton" />

    <ui:define name="implementation">
        
        <h:form>
            <h:panelGrid columns="2" style="margin-bottom:10px" cellpadding="5">
                <h:outputText value="Platform:" />
                <p:selectOneButton value="#{selectOneView.option}">
                    <f:selectItem itemLabel="Xbox One" itemValue="Xbox One" />
                    <f:selectItem itemLabel="PS4" itemValue="PS4" />
                    <f:selectItem itemLabel="Wii U" itemValue="Wii U" />
                </p:selectOneButton>
                
                <p:commandButton value="Submit" update="display" icon="pi pi-check" />
                <p:spacer />
                
                <h:outputText value="Selected:" />
                <h:outputText id="display" value="#{selectOneView.option}" style="font-weight: bold" />
            </h:panelGrid>
        </h:form>
        
    </ui:define>

</ui:composition>